package cn.gtlc.domain;

/**
 * @Description TODO
 * @Author Jowin
 * @Date 2023/5/28
 * @Version -
 */
public class Car {
    private String name;
    private String color;

    public Car() {
        System.out.println("----------Car()");
    }

    public Car(String name, String color) {
        this.name = name;
        this.color = color;
    }

    public void go() {
        System.out.println("name:" + name + "color:" + color + "Car->go()");
    }

    /**
     * 获取
     *
     * @return name
     */
    public String getName() {
        return name;
    }

    /**
     * 设置
     *
     * @param name
     */
    public void setName(String name) {
        this.name = name;
    }

    /**
     * 获取
     *
     * @return color
     */
    public String getColor() {
        return color;
    }

    /**
     * 设置
     *
     * @param color
     */
    public void setColor(String color) {
        this.color = color;
    }

    public String toString() {
        return "Car{name = " + name + ", color = " + color + "}";
    }
}
